SDA 3.5 Documentation for SDALOG
NAME
sdalog - Generate a report of SDA usage
USAGE
sdalog -g filename [options]
DESCRIPTION
SDALOG reads the SDA logfile (defined in a HARC file) and
generates a report on SDA usage. Note that the logfile read by
SDALOG is the special file written by SDA -- not the access log
maintained by the Web server software. See the [GENERAL] section
in the HARC file
document
for details on specifying the name of the logfile.
The default output format reports how many times each SDA program
or procedure was executed, how many times each dataset (using the
name specified in the HARC file) was accessed, and how many of
the reported procedures were run in each of the months.
An optional format (used if a ’-c’ option was specified) reports
the client IP addresses and how many times each client executed
an SDA procedure. This style of report can include the full IP
addresses or only the last one, two, or three final segments of
the IP addresses. For example, the last segment of the IP
address is the major Net domain -- like ’COM’ or ’EDU’. If the
’-c 1’ option is specified, a summary of usage by those major Net
domains will be generated.
OPTIONS
The following command-line options are recognized. The
specification of the name of the log file is required. The other
specifications are optional.
- -g filename
- The specified filename is the pathname of the log file
maintained by SDA, if such a file has been specified in a HARC
file. (REQUIRED)
- -o filename
- Output from SDALOG will be written to this file. If this
option is not specified, output will be routed to the user’s
screen (standard output).
- -e filename
- The specified filename contains, one per line, a list of
client IP addresses (or portions of addresses) to exclude from
the report. For example, the IP address used by the local system
programmer might be excluded from the usual reports. Note that
the IP addresses given in this file are treated as case-
insensitive. If ’.Com’ is specified, for example, all log
entries containing ’.COM’, or ’.com’ in the IP address field of
the log file will be excluded from the report.
- -f filter_string
- Each line of the logfile is scanned for the presence of the
specified string of characters. If the string is not in a line,
that line is excluded from the report.
This option can be repeated.
- -F filter_string
- The specified string of characters is used as a selection
filter (as with the ’-f’ option). However, the filter string is
case-insensitive. In other words, if the specified filter string
is ’gss’, lines containing ’gss’, ’GSS’, or ’Gss’ will all be
included in the report.
This option can be repeated.
- -c all
- The report will list the IP addresses of the client
computers used by the SDA users. The number of procedures
executed by each client will also be reported.
- -c 1
- Only the last segment of IP addresses (major Net domains
like EDU, COM, NET, etc.) will be reported (instead of the full
IP address of each user).
- -c 2
- The last 2 segments of IP addresses will be reported.
- -c 3
- The last 3 segments of IP addresses will be reported.
- -d number
- The specified number is the maximum length, in characters,
of a dataset name to process. If the log file is occasionally
written incorrectly by the system because of heavy Web usage,
some of the fields can be run together and produce what appear to
be long dataset names. Setting this option to ’10’, for example,
will cause the SDALOG program to skip any log entries with a
dataset name longer than 10 characters. This option would only
be used if the list of dataset names generated by the program
contained run-together names.
- -x filename
- Write lines with badly formed log entries (if any) into this
file. This option is for diagnostic purposes.
- -u
- Print out a list of options (but do not execute the program)
EXAMPLES
- Basic example
- sdalog -g SDAlog -o logreport
- Filter for a specific dataset (GSS)
- sdalog -g SDAlog -f GSS -o logreport
- Get major categories of users
- sdalog -g SDAlog -c 1 -o logreport
CSM, UC Berkeley
April 12, 2011